<!-- target: surpriseShopForm(master = formPage) -->
<!-- block: crumb -->
    <!-- import: surpriseShopFormCrumb -->
<!-- /block -->
<!-- block: formMain -->
    <!-- import: surpriseShopFormMain -->
<!-- /block -->

<!-- target: surpriseShopFormCrumb(master = crumb) -->
<!-- block: path -->
    <span>商户管理</span>
    <span><!-- if: ${formType} === 'create' -->新增<!-- else: -->编辑<!-- /if -->商户</span>
<!-- /block -->

<!-- target: surpriseShopFormMain(master = customFormView) -->
<!-- block: sections -->
    <!-- import: surpriseShopBaseContent -->
<!-- /block -->
<!-- block: submitSection -->
<button type="submit" data-ui-type="Button" data-ui-id="submit" data-ui-group="submit" data-ui-variants="warning wide" class="submit-button">确认提交</button>
<!-- /block -->

<!-- target: surpriseShopBaseContent -->
<section class="form-section">

    <!-- if: ${formType} === 'create' -->
    <div class="ui-form-row">
        <!-- use:
            textboxField(
                field = 'username',
                title = '登录用户名',
                length = 80,
                width = 200,
                required = true,
                description = '用户名不能修改'
            )
        -->
    </div>
    <!-- /if -->
    <!-- if: ${formType} === 'update' -->
    <div class="ui-form-row">
        <!-- use:
            labelField(text = ${username}, title = '登录用户名')
        -->
    </div>
    <!-- /if -->

    <div class="ui-form-row">
        <!-- use:
            textboxField(field = 'companyName', title = '商户名称', length = 120, width = 300, required = true)
        -->
    </div>
    
    <div class="ui-form-row">
        <!-- use:
            toggleSelectField(
                id = 'mall',
                field = 'mallid',
                width = 200,
                title = '购物中心',
                datasource = 'mallList'
            )
        -->
    </div>
    
    <div class="ui-form-row">
        <!-- use:
            textboxField(
                field = 'introduction',
                title = '商户介绍', 
                width = 400,
                height = 200,
                mode = 'textarea'
            )
        -->
    </div>
    
    <div class="ui-form-row">
        <!-- use:
            textboxField(
                field = 'chargePerson',
                title = '管理员名称',
                width = 200
            )
        -->
    </div>
    
    <div class="ui-form-row">
        <!-- use:
            textboxField(
                field = 'phone',
                title = '管理员电话',
                width = 200
            )
        -->
    </div>

        
    <div class="ui-form-row">
        <!-- use:
            timeField(
                dateField = 'startDate', timeField = 'startTime',
                title = '活动开始时间', timeList = ${timeList},
                required = true
            )
        -->
    </div>


    <div class="ui-form-row">
        <!-- use:
            timeField(
                dateField = 'endDate', timeField = 'endTime',
                title = '活动结束时间', timeList = ${timeList},
                required = true
            )
        -->
    </div>

    <div class="ui-form-row">
        <!-- use:
            textboxField(
                field = 'address',
                title = '地址',
                width = 300
            )
        -->
    </div>

    <div class="ui-form-row">
        <!-- use:
            logoField(
                title = '品牌LOGO',
                id = 'logo',
                field = 'logoType',
                fieldType = ${logoPic | indexOf('http')} === 0 ? 'pic' : 'text',
                uploadUrl = ${uploadUrl},
                textRequired = true,
                radioTab = true
            )
        -->
    </div>

    <div class="ui-form-row">
        <!-- use:
            uploaderWithPreviewField(
                field = 'qrcode', title = '商户二维码', imageWidth = 200,
                uploadUrl = ${uploadUrl}, required = true,
                descriptions = ['图片大小不超过1M']
            )
        -->
    </div>

</section>

